package core.manager.sceneManager
{
    import flash.events.*;

    public class SceneManagerProxy extends EventDispatcher
    {
        private static var instance:SceneManagerProxy;
        public var sceneManager:ISceneManager;
        public function SceneManagerProxy()
        {
            if (instance == null)
            {
                instance = this;
            }
            else
            {
                throw new Error("SceneManagerProxy不能实例化");
            }
            return;
        }// end function

        public function gotoScene(userEquation:int) : void
        {
            getInstance().dispatchEvent(new SceneManagerProxyEvent(SceneManagerProxyEvent.GOTOSCENE, userEquation));
            return;
        }// end function

        public static function getInstance() : SceneManagerProxy
        {
            if (instance == null)
            {
                return new SceneManagerProxy;
            }
            return instance;
        }// end function

    }
}
